
inline static uint32_t def_name(_inline_lsl)(uint32_t*reg,ui rd,uint32_t rn,uint32_t rm,uint32_t shift_n,int c){
    uint32_t cc;
    uint32_t op2 = Shift_C(&cc,rm,armo_lsl,shift_n,c);
    uint32_t result = _opr(reg,rd,rn,op2,reg,0,cc);
    //setflag(reg,result,0,cc);
    return result;
}

inline static uint32_t def_name(_inline_Slsl)(uint32_t*reg,ui rd,uint32_t rn,uint32_t rm,uint32_t shift_n,int c){
    uint32_t cc;
    uint32_t op2 = Shift_C(&cc,rm,armo_lsl,shift_n,c);
    uint32_t result = _opr(reg,rd,rn,op2,reg,1,cc);
    //setflag(reg,result,1,cc);
    return result;
}

inline static uint32_t def_name(_inline_lsr)(uint32_t*reg,ui rd,uint32_t rn,uint32_t rm,uint32_t shift_n,int c){
    uint32_t cc;
    uint32_t op2 = Shift_C(&cc,rm,armo_lsr,shift_n,c);
    uint32_t result = _opr(reg,rd,rn,op2,reg,0,cc);
    //setflag(reg,result,0,cc);
    return result;
}

inline static uint32_t def_name(_inline_Slsr)(uint32_t*reg,ui rd,uint32_t rn,uint32_t rm,uint32_t shift_n,int c){
    uint32_t cc;
    uint32_t op2 = Shift_C(&cc,rm,armo_lsr,shift_n,c);
    uint32_t result = _opr(reg,rd,rn,op2,reg,1,cc);
    //setflag(reg,result,1,cc);
    return result;
}

inline static uint32_t def_name(_inline_asr)(uint32_t*reg,ui rd,uint32_t rn,uint32_t rm,uint32_t shift_n,int c){
    uint32_t cc;
    uint32_t op2 = Shift_C(&cc,rm,armo_asr,shift_n,c);
    uint32_t result = _opr(reg,rd,rn,op2,reg,0,cc);
    //setflag(reg,result,0,cc);
    return result;
}

inline static uint32_t def_name(_inline_Sasr)(uint32_t*reg,ui rd,uint32_t rn,uint32_t rm,uint32_t shift_n,int c){
    uint32_t cc;
    uint32_t op2 = Shift_C(&cc,rm,armo_asr,shift_n,c);
    uint32_t result = _opr(reg,rd,rn,op2,reg,1,cc);
    //setflag(reg,result,1,cc);
    return result;
}

inline static uint32_t def_name(_inline_ror)(uint32_t*reg,ui rd,uint32_t rn,uint32_t rm,uint32_t shift_n,int c){
    uint32_t cc;
    uint32_t op2 = Shift_C(&cc,rm,armo_ror,shift_n,c);
    uint32_t result = _opr(reg,rd,rn,op2,reg,0,cc);
    //setflag(reg,result,0,cc);
    return result;
}

inline static uint32_t def_name(_inline_Sror)(uint32_t*reg,ui rd,uint32_t rn,uint32_t rm,uint32_t shift_n,int c){
    uint32_t cc;
    uint32_t op2 = Shift_C(&cc,rm,armo_ror,shift_n,c);
    uint32_t result = _opr(reg,rd,rn,op2,reg,1,cc);
    //setflag(reg,result,1,cc);
    return result;
}

//位移立即数为0
/////////////////////////////////////////////////////////////
inline static uint32_t def_name(_inline_lsl_immzero)(uint32_t*reg,ui rd,uint32_t rn,uint32_t rm,uint32_t shift_n,int c){
    uint32_t cc;
    uint32_t op2 = rm;
    cc = c;
    uint32_t result = _opr(reg,rd,rn,op2,reg,0,cc);
    //setflag(reg,result,0,cc);
    return result;
}

inline static uint32_t def_name(_inline_Slsl_immzero)(uint32_t*reg,ui rd,uint32_t rn,uint32_t rm,uint32_t shift_n,int c){
    uint32_t cc;
    uint32_t op2 = rm;
    cc = c;
    uint32_t result = _opr(reg,rd,rn,op2,reg,1,cc);
    //setflag(reg,result,1,cc);
    return result;
}

inline static uint32_t def_name(_inline_lsr_immzero)(uint32_t*reg,ui rd,uint32_t rn,uint32_t rm,uint32_t shift_n,int c){
    uint32_t cc;
    uint32_t op2 = Shift_C(&cc,rm,armo_lsr,32,c);
    uint32_t result = _opr(reg,rd,rn,op2,reg,0,cc);
    //setflag(reg,result,0,cc);
    return result;
}

inline static uint32_t def_name(_inline_Slsr_immzero)(uint32_t*reg,ui rd,uint32_t rn,uint32_t rm,uint32_t shift_n,int c){
    uint32_t cc;
    uint32_t op2 = Shift_C(&cc,rm,armo_lsr,32,c);
    uint32_t result = _opr(reg,rd,rn,op2,reg,1,cc);
    //setflag(reg,result,1,cc);
    return result;
}

inline static uint32_t def_name(_inline_asr_immzero)(uint32_t*reg,ui rd,uint32_t rn,uint32_t rm,uint32_t shift_n,int c){
    uint32_t cc;
    uint32_t op2 = Shift_C(&cc,rm,armo_asr,32,c);
    uint32_t result = _opr(reg,rd,rn,op2,reg,0,cc);
    //setflag(reg,result,0,cc);
    return result;
}

inline static uint32_t def_name(_inline_Sasr_immzero)(uint32_t*reg,ui rd,uint32_t rn,uint32_t rm,uint32_t shift_n,int c){
    uint32_t cc;
    uint32_t op2 = Shift_C(&cc,rm,armo_asr,32,c);
    uint32_t result = _opr(reg,rd,rn,op2,reg,1,cc);
    //setflag(reg,result,1,cc);
    return result;
}

inline static uint32_t def_name(_inline_ror_immzero)(uint32_t*reg,ui rd,uint32_t rn,uint32_t rm,uint32_t shift_n,int c){
    uint32_t cc;
    uint32_t op2 = Shift_C(&cc,rm,armo_rrx,reg[arm_cflag],c);
    uint32_t result = _opr(reg,rd,rn,op2,reg,0,cc);
    //setflag(reg,result,0,cc);
    return result;
}

inline static uint32_t def_name(_inline_Sror_immzero)(uint32_t*reg,ui rd,uint32_t rn,uint32_t rm,uint32_t shift_n,int c){
    uint32_t cc;
    uint32_t op2 = Shift_C(&cc,rm,armo_rrx,reg[arm_cflag],c);
    uint32_t result = _opr(reg,rd,rn,op2,reg,1,cc);
    //setflag(reg,result,1,cc);
    return result;
}

// add rd,rn,rm lsl imm
// add rd,rn,rm lsl rs
// add rd,rn,imm12
// add rd,rn,imm8
void def_name(lsl1)  (uint32_t*R,ui rd,ui rn,ui rm,uint32_t shift_n){def_name(_inline_lsl) (R,rd,R[rn],R[rm],shift_n,0); };
void def_name(lsl2)  (uint32_t*R,ui rd,ui rn,ui rm,ui rs){           def_name(_inline_lsl) (R,rd,R[rn],R[rm],R[rs],0); };
void def_name(lsr1)  (uint32_t*R,ui rd,ui rn,ui rm,uint32_t shift_n){def_name(_inline_lsr) (R,rd,R[rn],R[rm],shift_n,0); };
void def_name(lsr2)  (uint32_t*R,ui rd,ui rn,ui rm,ui rs){           def_name(_inline_lsr) (R,rd,R[rn],R[rm],R[rs],0); };
void def_name(asr1)  (uint32_t*R,ui rd,ui rn,ui rm,uint32_t shift_n){def_name(_inline_asr) (R,rd,R[rn],R[rm],shift_n,0); };
void def_name(asr2)  (uint32_t*R,ui rd,ui rn,ui rm,ui rs){           def_name(_inline_asr) (R,rd,R[rn],R[rm],R[rs],0); };
void def_name(ror1)  (uint32_t*R,ui rd,ui rn,ui rm,uint32_t shift_n){def_name(_inline_ror) (R,rd,R[rn],R[rm],shift_n,0); };
void def_name(ror2)  (uint32_t*R,ui rd,ui rn,ui rm,ui rs){           def_name(_inline_ror) (R,rd,R[rn],R[rm],R[rs],0); };
void def_name(lsl1_S)(uint32_t*R,ui rd,ui rn,ui rm,uint32_t shift_n){def_name(_inline_Slsl)(R,rd,R[rn],R[rm],shift_n,0); };
void def_name(lsl2_S)(uint32_t*R,ui rd,ui rn,ui rm,ui rs){           def_name(_inline_Slsl)(R,rd,R[rn],R[rm],R[rs],0); };
void def_name(lsr1_S)(uint32_t*R,ui rd,ui rn,ui rm,uint32_t shift_n){def_name(_inline_Slsr)(R,rd,R[rn],R[rm],shift_n,0); };
void def_name(lsr2_S)(uint32_t*R,ui rd,ui rn,ui rm,ui rs){           def_name(_inline_Slsr)(R,rd,R[rn],R[rm],R[rs],0); };
void def_name(asr1_S)(uint32_t*R,ui rd,ui rn,ui rm,uint32_t shift_n){def_name(_inline_Sasr)(R,rd,R[rn],R[rm],shift_n,0); };
void def_name(asr2_S)(uint32_t*R,ui rd,ui rn,ui rm,ui rs){           def_name(_inline_Sasr)(R,rd,R[rn],R[rm],R[rs],0); };
void def_name(ror1_S)(uint32_t*R,ui rd,ui rn,ui rm,uint32_t shift_n){def_name(_inline_Sror)(R,rd,R[rn],R[rm],shift_n,0); };
void def_name(ror2_S)(uint32_t*R,ui rd,ui rn,ui rm,ui rs){           def_name(_inline_Sror)(R,rd,R[rn],R[rm],R[rs],0); };

void def_name(lsl1_immzero)  (uint32_t*R,ui rd,ui rn,ui rm,uint32_t shift_n){def_name( _inline_lsl_immzero) (R,rd,R[rn],R[rm],shift_n,0); };
//void def_name(lsl2_immzero)  (uint32_t*R,ui rd,ui rn,ui rm,ui rs){           def_name( _inline_lsl_immzero) (R,rd,R[rn],R[rm],R[rs],0); };
void def_name(lsr1_immzero)  (uint32_t*R,ui rd,ui rn,ui rm,uint32_t shift_n){def_name( _inline_lsr_immzero) (R,rd,R[rn],R[rm],shift_n,0); };
//void def_name(lsr2_immzero)  (uint32_t*R,ui rd,ui rn,ui rm,ui rs){           def_name( _inline_lsr_immzero) (R,rd,R[rn],R[rm],R[rs],0); };
void def_name(asr1_immzero)  (uint32_t*R,ui rd,ui rn,ui rm,uint32_t shift_n){def_name( _inline_asr_immzero) (R,rd,R[rn],R[rm],shift_n,0); };
//void def_name(asr2_immzero)  (uint32_t*R,ui rd,ui rn,ui rm,ui rs){           def_name( _inline_asr_immzero) (R,rd,R[rn],R[rm],R[rs],0); };
void def_name(ror1_immzero)  (uint32_t*R,ui rd,ui rn,ui rm,uint32_t shift_n){def_name( _inline_ror_immzero) (R,rd,R[rn],R[rm],shift_n,0); };
//void def_name(ror2_immzero)  (uint32_t*R,ui rd,ui rn,ui rm,ui rs){           def_name( _inline_ror_immzero) (R,rd,R[rn],R[rm],R[rs],0); };
void def_name(lsl1_S_immzero)(uint32_t*R,ui rd,ui rn,ui rm,uint32_t shift_n){def_name(_inline_Slsl_immzero)(R,rd,R[rn],R[rm],shift_n,0); };
//void def_name(lsl2_S_immzero)(uint32_t*R,ui rd,ui rn,ui rm,ui rs){           def_name(_inline_Slsl_immzero)(R,rd,R[rn],R[rm],R[rs],0); };
void def_name(lsr1_S_immzero)(uint32_t*R,ui rd,ui rn,ui rm,uint32_t shift_n){def_name(_inline_Slsr_immzero)(R,rd,R[rn],R[rm],shift_n,0); };
//void def_name(lsr2_S_immzero)(uint32_t*R,ui rd,ui rn,ui rm,ui rs){           def_name(_inline_Slsr_immzero)(R,rd,R[rn],R[rm],R[rs],0); };
void def_name(asr1_S_immzero)(uint32_t*R,ui rd,ui rn,ui rm,uint32_t shift_n){def_name(_inline_Sasr_immzero)(R,rd,R[rn],R[rm],shift_n,0); };
//void def_name(asr2_S_immzero)(uint32_t*R,ui rd,ui rn,ui rm,ui rs){           def_name(_inline_Sasr_immzero)(R,rd,R[rn],R[rm],R[rs],0); };
void def_name(ror1_S_immzero)(uint32_t*R,ui rd,ui rn,ui rm,uint32_t shift_n){def_name(_inline_Sror_immzero)(R,rd,R[rn],R[rm],shift_n,0); };
//void def_name(ror2_S_immzero)(uint32_t*R,ui rd,ui rn,ui rm,ui rs){           def_name(_inline_Sror_immzero)(R,rd,R[rn],R[rm],R[rs],0); };


void def_name(imm12)    (uint32_t*R,ui rd,ui rn,ui imm12){ def_name(_inline_ror)( R,rd,R[rn],imm12&0xff,2*((imm12>>0x8)&0xf),0); };
void def_name(imm8)     (uint32_t*R,ui rd,ui rn,ui imm8) { def_name(_inline_lsl)( R,rd,R[rn],imm8,0,0); };
void def_name(imm12_S)  (uint32_t*R,ui rd,ui rn,ui imm12){ def_name(_inline_Sror)(R,rd,R[rn],imm12&0xff,2*((imm12>>0x8)&0xf),0); };
void def_name(imm8_S)   (uint32_t*R,ui rd,ui rn,ui imm8) { def_name(_inline_Slsl)(R,rd,R[rn],imm8,0,0); /*imm8 应该是lsl才对，这样不会处理标识符*/ };

void def_name(imm_ror)    (uint32_t*R,ui rd,ui rn,ui imm8,ui shift_n){ def_name(_inline_ror)( R,rd,R[rn],imm8,2*shift_n,0); };
void def_name(imm_ror_S)  (uint32_t*R,ui rd,ui rn,ui imm8,ui shift_n){ def_name(_inline_Sror)(R,rd,R[rn],imm8,2*shift_n,0); };
